package com.example.lib_net.interceptor

import okhttp3.Interceptor
import okhttp3.Request
import okhttp3.Response


class HttpHeaderInterceptor:Interceptor {
    override fun intercept(chain: Interceptor.Chain): Response {
        val original = chain.request()
        val requestBuilder = original.newBuilder()
            .addHeader("content-type", "application/json")
            .addHeader("accessId", "f2fb416f9fa54e83b16435a90d9e7f0a")
            //.addHeader("token", AuthMMKV.token)
            .addHeader("token", "1")
        val request: Request = requestBuilder.build()
        return chain.proceed(request)
    }
}